#region

using System;
using DevTools.EventStuffGenerator.Components;

#endregion

namespace DevTools.ModelStuffGenerator.Controls
{
    public partial class InputControl : RootUserControl
    {
        public InputControl()
        {
            InitializeComponent();

            bdsHistory.DataSource = HistoryManager.Instance;
        }

        public string ClassName
        {
            get { return txtClassName.Text; }
        }

        public string Argument
        {
            get { return txtArgument.Text; }
        }

        private void lueHistory_EditValueChanged(object sender, EventArgs e)
        {
            HistoryItem historyItemItem = (HistoryItem) lueHistory.EditValue;

            txtClassName.Text = historyItemItem.EventName;
            txtArgument.Text = historyItemItem.Argument;
        }
    }
}